package com.to8to.autotask.newlundan.entity;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;

import org.elasticsearch.common.collect.Lists;
import org.elasticsearch.common.collect.Maps;
import org.elasticsearch.common.collect.Sets;

//公司的设计师数量（需要从to8to_twenty表中查询）、办公面积、注册资金、注册时间等参数暂时不设置。
public class Company
{
    /**
     * 公司id
     */
    private int _id;

    /**
     * 施工资质
     */
    private int aptrank;

    /**
     * 每月轮标下限
     */
    private int monthlylimit;

    /**
     * 每月轮标上限
     */
    private int upperlimit;

    /**
     * 是否是A类公司，如果有monthlylimit，则为A类公司
     */
    private boolean isClassA;

    /**
     * 量房成功数
     */
    private int lfSuccCount;

    /**
     * 分配项目的个数
     */
    private int fpCount;

    /**
     * 子公司数
     */
    private int subcomCount;

    /**
     * 当月项目分配个数
     */
    private int monthFpCount;

    /**
     * 办公面积
     */
    private double officeArea;

    /**
     * 创建时间
     */
    private int createTime;

    /**
     * 注册资金
     */
    private int registMoney;

    /**
     * 余额，对应于表中的cancost
     */
    private double balance;

    /**
     * 是否有可用余额（当balance大于该公司类型对应的最小轮单费用时表示有可用余额）
     */
    private boolean hasBalance;

    /**
     * 口碑评分
     */
    private double koubei;

    /**
     * 信用度
     */
    private double xinyong;

    /**
     * 休息日，周几
     */
    private int dayoff;

    /**
     * 分公司的坐标集合
     */
    private List<GeoPoint> locations = new ArrayList<GeoPoint>();

    /**
     * 轮单记录
     */
    private List<ZXBOrder> zxbOrders = new ArrayList<ZXBOrder>();

    /**
     * 不同价位剩余的消耗次数的映射
     */
    private Map<String, Integer> tbnumsMap = new HashMap<String, Integer>();

    /**
     * 不同价位的分配数
     */
    private Map<String, Integer> priceFpMap = new HashMap<String, Integer>();

    /**
     * 工地、案例信息
     */
    private List<GDInfo> gdList = Lists.newArrayList();

    /**
     * 风格，用case表中的风格
     */
    private Set<Integer> styles = Sets.newHashSet();

    /**
     * 区和工地数量的映射。key：townid
     */
    private Map<Integer, Integer> townGDMap = Maps.newHashMap();

    //中标 key pricelevel
    private Map<Integer, Integer> zbCountMap;

    public int get_id()
    {
        return _id;
    }

    public void set_id(int _id)
    {
        this._id = _id;
    }

    public int getAptrank()
    {
        return aptrank;
    }

    public void setAptrank(int aptrank)
    {
        this.aptrank = aptrank;
    }

    public int getMonthlylimit()
    {
        return monthlylimit;
    }

    public void setMonthlylimit(int monthlylimit)
    {
        this.monthlylimit = monthlylimit;
    }

    public int getLfSuccCount()
    {
        return lfSuccCount;
    }

    public void setLfSuccCount(int lfSuccCount)
    {
        this.lfSuccCount = lfSuccCount;
    }

    public double getOfficeArea()
    {
        return officeArea;
    }

    public void setOfficeArea(double officeArea)
    {
        this.officeArea = officeArea;
    }

    public int getSubcomCount()
    {
        return subcomCount;
    }

    public void setSubcomCount(int subcomCount)
    {
        this.subcomCount = subcomCount;
    }

    public int getRegistMoney()
    {
        return registMoney;
    }

    public void setRegistMoney(int registMoney)
    {
        this.registMoney = registMoney;
    }

    public int getCreateTime()
    {
        return createTime;
    }

    public void setCreateTime(int createTime)
    {
        this.createTime = createTime;
    }

    public List<GeoPoint> getLocations()
    {
        return locations;
    }

    public void setLocations(List<GeoPoint> locations)
    {
        this.locations = locations;
    }

    public int getMonthFpCount()
    {
        return monthFpCount;
    }

    public void setMonthFpCount(int monthFpCount)
    {
        this.monthFpCount = monthFpCount;
    }

    public int getDayoff()
    {
        return dayoff;
    }

    public void setDayoff(int dayoff)
    {
        this.dayoff = dayoff;
    }

    public List<GDInfo> getGdList()
    {
        return gdList;
    }

    public void setGdList(List<GDInfo> gdList)
    {
        this.gdList = gdList;
    }

    public Set<Integer> getStyles()
    {
        return styles;
    }

    public void setStyles(Set<Integer> styles)
    {
        this.styles = styles;
    }

    public Map<Integer, Integer> getTownGDMap()
    {
        return townGDMap;
    }

    public void setTownGDMap(Map<Integer, Integer> townGDMap)
    {
        this.townGDMap = townGDMap;
    }

    public Map<Integer, Integer> getZbCountMap()
    {
        return zbCountMap;
    }

    public void setZbCountMap(Map<Integer, Integer> zbCountMap)
    {
        this.zbCountMap = zbCountMap;
    }

    public List<ZXBOrder> getZxbOrders()
    {
        return zxbOrders;
    }

    public void setZxbOrders(List<ZXBOrder> zxbOrders)
    {
        this.zxbOrders = zxbOrders;
    }

    public double getBalance()
    {
        return balance;
    }

    public void setBalance(double balance)
    {
        this.balance = balance;
    }

    public boolean isClassA()
    {
        return isClassA;
    }

    public void setClassA(boolean isClassA)
    {
        this.isClassA = isClassA;
    }

    public boolean isHasBalance()
    {
        return hasBalance;
    }

    public void setHasBalance(boolean hasBalance)
    {
        this.hasBalance = hasBalance;
    }

    public double getKoubei()
    {
        return koubei;
    }

    public void setKoubei(double koubei)
    {
        this.koubei = koubei;
    }

    public Map<String, Integer> getTbnumsMap()
    {
        return tbnumsMap;
    }

    public int getUpperlimit()
    {
        return upperlimit;
    }

    public void setUpperlimit(int upperlimit)
    {
        this.upperlimit = upperlimit;
    }

    public double getXinyong()
    {
        return xinyong;
    }

    public void setXinyong(double xinyong)
    {
        this.xinyong = xinyong;
    }

    public int getFpCount()
    {
        return fpCount;
    }

    public void setFpCount(int fpCount)
    {
        this.fpCount = fpCount;
    }

    public Map<String, Integer> getPriceFpMap()
    {
        return priceFpMap;
    }

    public void setTbnumsMap(Map<String, Integer> tbnumsMap)
    {
        this.tbnumsMap = tbnumsMap;
    }

    public void setPriceFpMap(Map<String, Integer> priceFpMap)
    {
        this.priceFpMap = priceFpMap;
    }
}
